home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Technotools
/
Technotools (Chestnut CD-ROM)(1993).ISO
/
lang_c
/
mc51bugs
/
q37337
< prev
next >
Wrap
Text File
|
1988-11-18
|
1KB
|
38 lines
Q37337 Floating-Point Error: infinity/infinity Hangs on 8087
C Compiler
5.00 5.10
MS-DOS
Summary:
The program below demonstrates a problem with the Microsoft
floating-point error handling routines when run on an 8086- (or 8088-)
based machine with an 8087 coprocessor.
Microsoft has confirmed this to be a problem in Version 5.10. We are
researching this problem and will post new information as it becomes
available.
More Information:
The program below should generate the following error:
run-time error M6101: MATH
- floating-point error: invalid.
The program is as follows:
main()
{
double x,y;
y = *(double *) "\0\0\0\0\0\0\xf0\x7f"; /* y = infinity */
x = y/y; /* floating point exception infinity/infinity */
}
The program executes as expected on machines with a 80287 or 80387
math coprocessor, or with machines without a coprocessor. On machines
with a 8087 math coprocessor, the program hangs the machine.
Keywords: buglist5.10
Updated 88/11/19 08:01